## @file
#
# Copyright (C) 2022, Phytium Technology Co., Ltd. All rights reserved.<BR>
#
# SPDX-License-Identifier:BSD-2-Clause-Patent
#
##

[LibraryClasses.common]
  #
  # Platform and memory configuration library
  #
  ArmPlatformLib|$(SILICON_PACKAGE)/Library/PlatformLib/PlatformLib.inf


  #
  # Parameter Table Driver
  #
  ParameterTableLib|$(SILICON_PACKAGE)/Library/ParameterTableLib/ParameterTable.inf

[LibraryClasses.common.DXE_DRIVER]
  #
  # Pci dependencies
  #
  PciSegmentLib|$(SILICON_PACKAGE)/Library/PciSegmentLib/PciSegmentLib.inf
  PciHostBridgeLib|$(SILICON_PACKAGE)/Library/PciHostBridgeLib/PciHostBridgeLib.inf
  PciLib|MdePkg/Library/BasePciLibPciExpress/BasePciLibPciExpress.inf
  PciExpressLib|MdePkg/Library/BasePciExpressLib/BasePciExpressLib.inf

################################################################################
#
# Pcd Section - list of all EDK II PCD Entries defined by this Platform
#
################################################################################
[PcdsFixedAtBuild.common]
  #
  # ParaTable Base
  #
  gPhytiumPlatformTokenSpaceGuid.PcdParameterTableBase|0xc8000
  gPhytiumPlatformTokenSpaceGuid.PcdParameterPllOffset|0x0
  gPhytiumPlatformTokenSpaceGuid.PcdParameterCommonOffset|0x100
  gPhytiumPlatformTokenSpaceGuid.PcdParameterDdrOffset|0x200
  gPhytiumPlatformTokenSpaceGuid.PcdParameterBoardOffset|0xe00
  gPhytiumPlatformTokenSpaceGuid.PcdParameterSecureOffset|0x400
  gPhytiumPlatformTokenSpaceGuid.PcdParameterC2COffset|0x500
  gPhytiumPlatformTokenSpaceGuid.PcdParameterPcieOffset|0x600

  #
  # PCIE
  #
  gEfiMdePkgTokenSpaceGuid.PcdPciExpressBaseAddress|0x40000000
  gPhytiumPlatformTokenSpaceGuid.PcdPciConfigBase|0x40000000
  gPhytiumPlatformTokenSpaceGuid.PcdPciConfigSize|0x10000000
  gArmTokenSpaceGuid.PcdPciBusMin|0
  gArmTokenSpaceGuid.PcdPciBusMax|255
  gArmTokenSpaceGuid.PcdPciIoBase|0x00000
  gArmTokenSpaceGuid.PcdPciIoSize|0xf00000
  gArmTokenSpaceGuid.PcdPciMmio32Base|0x58000000
  gArmTokenSpaceGuid.PcdPciMmio32Size|0x8000000
  gArmTokenSpaceGuid.PcdPciMmio64Base|0x40000000000
  gArmTokenSpaceGuid.PcdPciMmio64Size|0x10000000000

[PcdsDynamicDefault.common]
  #
  # This dynamic PCD disable or enable PCI support.
  #
  gEfiMdeModulePkgTokenSpaceGuid.PcdPciDisableBusEnumeration|FALSE

################################################################################
#
# Components Section - list of all EDK II Modules needed by this Platform
#
################################################################################
[Components.common]
  #
  # PEI driver
  #
  $(SILICON_PACKAGE)/PlatformPei/PlatformPeim.inf

  #
  # Spi driver
  #
  $(SILICON_PACKAGE)/Drivers/SpiDxe/SpiDxe.inf

  #
  # NOR Flash driver
  #
  $(SILICON_PACKAGE)/Drivers/SpiNorFlashDxe/SpiNorFlashDxe.inf

  #
  # PCI Support
  #
  ArmPkg/Drivers/ArmPciCpuIo2Dxe/ArmPciCpuIo2Dxe.inf
  MdeModulePkg/Bus/Pci/PciHostBridgeDxe/PciHostBridgeDxe.inf
  MdeModulePkg/Bus/Pci/PciBusDxe/PciBusDxe.inf
  MdeModulePkg/Bus/Pci/NonDiscoverablePciDeviceDxe/NonDiscoverablePciDeviceDxe.inf
